# -*- coding:utf-8 -*-


ENV_CODE = 2

# PG_DSN = 'host=pg.localdomain dbname={} user=root password=Boluome123'
PG_DSN = 'host=192.168.0.67 dbname={} user=root password=blm123'

PG_PAY_SCHEMA = {
    'name': str,
    'orderid': str,
    'userid': str,
    'channel': str,
    'chargeid': str,
    'ordertype': str,
    'price': int,
    'payprice': int,
    'status': int,
    'appcode': str,
    'createdat': int,
    'serial': str
}

PG_REFUND_SCHEMA = {
    'name': str,
    'orderid': str,
    'userid': str,
    'ordertype': str,
    'price': int,
    'refundedprice': int,
    'paidprice': int,
    'refundedtimeline': int,
    'timeline': int,
    'appcode': str,
    'createdat': int
}

APP_CODE = ['zjrcu', 'icbc', 'linshangbank', 'qilubank', 'yantaibank', 'laishangbank', '51jiedao', 'ppdai', 'mallicbc',
            'rizhaobank', 'fdbank', 'doooly', 'rxjt', 'trcbank']
APP_URL = 'http://paymentapi.localdomain:32028/{}/payment/status/v1'
APP_URL_EXPIRE_32039 = 'http://lb10.localdomain:32039/{}/payment/status/v1'

NOTICE_JAVA_URL = 'http://kongintoin.localdomain:8000/api/customer/service/special/v1?orderId={}'

MONGO_URI = 'mongodb://root:Boluome123@mongo-m.localdomain,mongo-s1.localdomain,mongo-s2.localdomain/?authSource=admin&replicaSet=foba&readPreference=primaryPreferred'

MONGO_FETCH_URI = 'mongodb://root:Boluome123@mongo-m.localdomain,mongo-s.localdomain,mongo-s2.localdomain/?authSource=admin&replicaSet=foba&readPreference=secondaryPreferred'

MONGO_COLL = {
    'huafei': 'order_huafei',
    'liuliang': 'order_liuliang',
    'dianying': 'order_dianying',
    'jipiao': 'order_jipiao',
    'menpiao': 'order_menpiao',
    'waimai': 'order_waimai',
    'daijia': 'order_daijia',
    'huoche': 'order_huoche',
    'jiudian': 'order_jiudian',
    'balance': 'order_balance',
    'paotui': 'order_paotui',
    'zhuanche': 'order_zhuanche',
    'shengxian': 'order_shengxian',
    'piaowu': 'order_piaowu',
    'xihu': 'order_xihu',
    'coffee': 'order_coffee',
    'jiadianqingxi': 'order_jiadianqingxi',
    'jiadianweixiu': 'order_jiadianweixiu',
    'xianhua': 'order_xianhua',
    'weizhang': 'order_weizhang',
    'baoyang': 'order_baoyang',
    'shenghuojiaofei': 'order_shenghuojiaofei',
    'jiayouka': 'order_jiayouka',
    'dengjifuwu': 'order_dengjifuwu'
}

REDIS_HOST = 'masterredis-rw.localdomain'
REDIS_PORT = 6379
REDIS_DB = 0
REDIS_RETRY_DB = 1

# PAYMENT_REDIS_HOST = 'paymentredis-rw.localdomain'
# PAYMENT_REDIS_HOST = '192.168.0.67'
PAYMENT_REDIS_HOST = '192.168.0.6'
REDIS_PAYMENT_DB = 1
REDIS_REFUND_DB = 2
REDIS_BALANCE_DB = 3

ACTIVITY_REDIS_HOST = 'activityredis.localdomain'
REDIS_ACTIVITY_CACHE_DB = 3
RDDB_HOST = 'rederedis.localdomain'  # ReDe

RRDB_HOST = 'rrdb.localdomain'
RRDB_PORT = 16379
RRDB_DB = 0

# MQ_BROKER = 'amqp://blm:blm123@mq.localdomain//'
MQ_BROKER = 'amqp://blm:blm123@192.168.0.67//'
#MQ_BROKER = 'amqp://blm:blm123@192.168.0.2//'

MQ_EXPIRE = 'expire_tasks'
MQ_CANCEL = 'cancel_tasks'
MQ_COMPLETE = 'complete_tasks'
MQ_REFUND = 'refund_tasks'
MQ_PUSH = 'push_tasks'
MQ_SYNC = 'sync_tasks'
MQ_PAY = 'pay_tasks'
MQ_SMS = 'sms_tasks'
MQ_MAIL = 'mail_tasks'
MQ_NEWER = 'newer_tasks'
MQ_DDTJ = 'ddtj_tasks'
MQ_PRE_REPORT = 'pre_report_tasks'

MQ_AI = 'ai_tasks'
MQ_DHST = 'dhst_tasks'
MQ_TFLOW = 'tflow_tasks'
MQ_SINOPEC = 'sinopec_tasks'
MQ_DIDI = 'didi_tasks'
MQ_SHENZHOU = 'shenzhou_tasks'
MQ_E = 'e_tasks'
MQ_ELE = 'ele_tasks'
MQ_KOU = 'kou_tasks'
MQ_LINQU = 'linqu_tasks'
MQ_CX = 'cx_tasks'
MQ_OF = 'of_tasks'
MQ_JUHE = 'juhe_tasks'
MQ_QUYIYUAN = 'quyiyuan_tasks'
MQ_ZZW = 'zzw_tasks'
MQ_MAOYAN = 'maoyan_tasks'
MQ_YIDAO = 'yidao_tasks'
MQ_YIGUO = 'yiguo_tasks'
MQ_ZHENLV = 'zhenlv_tasks'
MQ_YONGLE = 'yongle_tasks'
MQ_SFDJ = 'sfdj_tasks'
MQ_CTRIP = 'ctrip_tasks'
MQ_MONITOR = 'monitor_tasks'
MQ_LVMAMA = 'lvmama_tasks'
MQ_TONGCHENG = 'tongcheng_tasks'
MQ_WAKE = 'wake_tasks'
MQ_KAOLA = 'kaola_tasks'
MQ_MEITUAN = 'meituan_tasks'
MQ_SYNC_FLOW = "sync_flow_tasks"
MQ_SYNC_FLOW_ADD_TASK = "sync_flow_add_task"
MQ_TAOPIAOPIAO = 'taopiaopiao_tasks'
MQ_ALARM = 'alarm_tasks'
MQ_YONGCHE = 'yongche_tasks'
MQ_AUTO_REFUND = 'auto_refund_tasks'
MQ_DAIJIA = 'daijia_tasks'
MQ_YANGCHE = 'yangche_tasks'
MQ_FAPIAO = 'fapiao_tasks'
MQ_BOSS = 'boss_tasks'
MQ_ELIMINATE = 'eliminate_tasks'
MQ_PAYTICKET = 'payticket_tasks'
MQ_CHEXINGYI = 'chexingyi_tasks'
MQ_ZIYOUXING = 'ziyouxing_tasks'
MQ_YONGCHE_TSHJ = 'yongche_tshj_tasks'

SYNC_EXCHANGE = 'order_status'
SYNC_STATUS_APP_CODE_LIST = {
    "allinpay",
    "chubao",
    "jst",
    "scity",
    "91ala",
    "zuwoojia",
    "autohome",
    "pingan-one",
    "beebill",
    "zybank",
    "oklife",
    "anydoor",
    "fxbank",
    "smy",
}

FLOW_EXCHANGE = 'flow'
# ziyouxing
HUIJI_HOP_ID = '5c7770770a5872486d38c8f7'
HUIJI_HOP_SECRET = '401dbd1e4c8b3d7301a5f07020d8e0e5'
HUIJI_HOST_URL = 'http://jd.hop.huijimall.com/hop/action'

# taopiaopiao
TAOPP_PLATFORM = 73
TAOPP_URL = 'http://gw.api.taobao.com/router/rest'
TAOPP_STATUS_API = 'taobao.film.data.third.party.issue.order'
TAOPP_CONSUME_API = 'taobao.tmc.messages.consume'
TAOPP_CONFIRM_API = 'taobao.tmc.messages.confirm'
TAOPP_SECRET = '4711690bf957dc7c74c7a9b238f20abb'
TAOPP_APPKEY = '24908070'
TAOPP_USER_ID = 1835522606

# daijia didi
DAIJIA_URL = 'https://daijia.kuaidadi.com/gateway'
DAIJIA_APPKEY = 'd1f2961fccbd4134a731244a19c94b2c'
DAIJIA_APPSECRET = '21e06634f1c54f658083d043b8766e5d'
DAIJIA_LOGIN_API = 'lj.nbs.u.loginbyTp'
DAIJIA_DRIVER_STATUS_API = 'lj.nbs.o.getDriverStatusMsg'
DAIJIA_CUSTOMERKEY = 'MTA4Mw=='
DAIJIA_PRIVILEGEID = 2486

# yangche -- diandian
# YANGCHE_APP_KEY = '4MHSJK9LOTX6BJCJ'
# YANGCHE_APP_SECRET = '5E13JM02J2RFQ2351Y3KFI3Q7T60G0LF'
# YANGCHE_BASE_URL = 'https://int-open.ddyc.com'
YANGCHE_APP_KEY = 'UCTN2G2B6TDQIQZS'
YANGCHE_APP_SECRET = '4IZT8V071EZR7FG2FIJCWS4VC7RZ95UF'
YANGCHE_BASE_URL = 'https://openapi.ddyc.com'
YANGCHE_ORDER_DETAIL_URI = '/orderCenter/order/detail'
YANGCHE_ORDER_PAY_TRADE_URI = '/pay/trade/pre'
YANGCHE_ORDER_RESULT_URI = '/orderCenter/order/status'
YANGCHE_HEADER = {'app_key': YANGCHE_APP_KEY}
# yongche -- didi
DIDI_URL = 'http://api.es.xiaojukeji.com'
DIDI_AUTH_URL = '/v1/Auth/authorize'
DIDI_CITY_URL = '/v1/common/Cities/getAll'
DIDI_ORDER_URL = '/v1/order/Detail/getOrderDetail'
DIDI_FEECONFIRM_URL = '/v1/order/FeeConfirm'
# pro
DIDI_YONGCHE_SIGN_KEY = 'c666B7EF828941776c45'
DIDI_CLIENT_ID = '1f434096266efbbd37bd2921022af1ff'
DIDI_CLIENT_SECRET = 'd8736e0898f3f41df1288a7d45455989'
DIDI_PHONE = '18717702883'

# yonghce caocao
CAOCAO_URL = 'https://cop.caocaokeji.cn'
CAOCAO_ORDER_URL = '/v2/common/queryOrderDetailV2'
CAOCAO_CLIENT_ID = 'acf090c831823fcb'
CAOCAO_SIGN_KEY = '85be19d7a42a335648dde3a1f2ea75cd'
CAOCAO_YONGCHE_URL = 'http://yongcheapi.localdomain:31007/orderSettlemetnAndUpdateStatus'
CAOCAO_REFUND_URL = 'http://yongcheapi.localdomain:31007/auto/deduction'

# 用车 同时呼叫
YONGCHE_SAME_TIME = 'http://yongcheapi.localdomain:31007/call/order/cancel'
# yongche shouqi
SHOUQI_KEY = '!WCDNohke3ZmY3$aJ'
SHOUQI_CHANNEL = 'shkp'
SHOUQI_ORDER_STATUS_URL = 'https://openapi.01zhuanche.com/touch/partner/v2/pollingOrderStatus'
SHOUQI_DRIVER_LOCATION_URL = 'https://openapi.01zhuanche.com/touch/partner/v2/driverLocation'

order_successfully = {
    'code': 9,
    'msg': '接单成功',
    'subStatus': 910,
}
# driver_start = {
#         'code': 9,
#         'msg': '司机出发',
#         'subStatus': 915,
#     }
driver_arrived = {
    'code': 9,
    'msg': '司机到达',
    'subStatus': 920,
}
in_progress = {
    'code': 9,
    'msg': '行程中',
    'subStatus': 930,
}
end_trip = {
    'code': 9,
    'msg': '计费中',
    'subStatus': 940,
}
# yongche boss退款接口
BOSS_REFUND_URL = 'http://192.168.1.30:38811/v1/customer/intranet/orders/{}/refund'

# 罚单缴费  后端提供跨加解密的外网接口
FADANJIAOFEI_ORDER_URL = 'http://fadanjiaofeiapi.localdomain:31066/fadanjiaofei/v1/order?id={}'

# 年检代办  后端提供跨加解密的外网接口
NIANJIANDAIBAN_ORDER_URL = 'http://blm.otosaas.com/api/nianjiandaijiao/v1/order/info?id={}'

# didi
DIDI_ID = {'fixed': 'otosaas', 'realtime': 'otosaas-rt'}
DIDI_SIGN_KEY = {'fixed': '#otosaas#i.({%yUqW_Klm~juo~LzXdv~<IQvM*se#didi#',
                 'realtime': '#otosaas#i.({%yUqW_Klm~juo~LzXdv~<IQvM*se#didi#'}
DIDI_HOST = 'https://api.xiaojukeji.com/'

# shenzhou.pro
SHENZHOU_CLIENT_ID = {'fixed': '15BF033E0000320A', 'realtime': '15BF033E0000310A'}
SHENZHOU_CLIENT_SECRET = {'fixed': 'hyvi8t12swdia35m9tk0', 'realtime': 'g4uq7svk0h2cewn7fhwm'}
SHENZHOU_OAUTH_URL = 'https://oauth.10101111.com'
SHENZHOU_URL = 'https://openapi.10101111.com'
SHENZHOU_GRANT_TYPE = 'password'
SHENZHOU_COMPAY_ID = '32305'
SHENZHOU_USER_NAME = '13162081070'
SHENZHOU_PASS_WORD = 'Blm.123'

# yidao
YIDAO_HOST = 'https://yop.yongche.com/v2'
YIDAO_TOKEN = 'YYYlyvNPPmeiJwJlPJY8VjvTlnuUPxHejQ1qqEBf'

# ai
AI_SIGN = 'f53fa2b64a2fbd3b8540a123a1929d24'
AI_URL = 'http://p.aidaijia.com/pservice.aspx'
AI_HEADERS = {'Content-Type': 'application/x-www-form-urlencoded'}

# an
# AN_HOST = 'http://open.andaijia.com'
# AN_AGENT_ID = 5231
# AN_KEY = 'boluomi1016'
# AN_SALT = '824467f81398b7213e69597a369beb01'
# AN_PASSWORD = '52555cc89e91c0f2188f88304d210ea0'
# AN_VER = '1.0'


# e
E_HOST = 'http://open.api.edaijia.cn'
E_APP_KEY = '61000139'
E_SECRET = 'e178cd91-6de8-4e1d-813f-b8f962ae4c09'
E_FROM = '01050273'
E_VER = '3.3'
E_PUB_KEY = '''-----BEGIN PUBLIC KEY-----
MIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQC0B4jUpGTVYzpZVv+aH64CbUfv
ZRaovcT4qVgzXGGbHVDqkxT5h24LtgSJg6nvAHscsXXuA63M0Hpyi0CTD8nEGzk1
SeLW+zX8irxGC9yfPusCOJxaOI24PNnJo91Nxxj8+OWVBYfUuOL0L0h9oHGC9mHO
ho7JMFmZu8mI+KB5VwIDAQAB
-----END PUBLIC KEY-----'''

# ele
ELE_HOST = 'https://openapi.ele.me/v2'
ELE_CONSUMER_KEY = '5634882370'
ELE_CONSUMER_SECRET = 'f754a8c2efe5a98fba814cc94971dcd6793945c0'
# eleb
ELEB_CONSUMER_NO = '201810161545914444'
ELEB_CONSUMER_SECRET = 'kli12323ea520a5fa7b895e49ioqpwdl21'
ELEB_BASE_URL = 'https://enterprise-open-api.ele.me'
ELEB_ORDER_STARTUS_URL = '/v1/openapi/order/getStatus'

# ele上塔
SHANGTA_BASE_URL = 'http://kongnetout.localdomain:8000'
SHANGTA_LOCATION_URL = '/waimai/v1/eleb/openapi/order/getTrackingInfo?partnerId={}'
SHANGTA_ELE_ORDER_STATUS = '/waimai/v1/ele/order/status?partnerId={}'
SHANGTA_ELEB_ORDER_STATUS = '/waimai/v1/eleb/openapi/order/status/?partnerId={}'
# bestpay 状态推送API
BESTPAY_HOST = 'https://e-commerce.bestpay.com.cn'
BESTPAY_CODE = "el_00001"
BESTPAY_OTOSAAS_HOST = "https://bestpay.otosaas.com"

# zzw
ZZW_URL = 'http://filmapi.spider.com.cn/v2/boluomi/qryOrderStatus.html'
ZZW_KEY = 'boluomi'
ZZW_SECRET = 'BV07RK5W9U3Z'

# kou
KOU_URL = 'http://api.komovie.cn/movie/service'
KOU_CHANNEL_ID = '189'
KOU_MD5_KEY = 'GglrL3WIjp6CUZnj'
KOU_ACTION = 'order_Query'

# maoyan
MAOYAN_ID = "1000058"
MAOYAN_KEY = "cw8jhcd1lld0b5c3szq890wgxrq376cc"
MAOYAN_URL = "http://open.maoyan.com/api/"

# juhe pro
JUHE_URL = "http://118.178.154.180:8899/bc/order/search"
JUHE_KEY = "608ed1d0ed8a00362b2be4604ef7acbe"
JUHE_UID = 'zhangxin365'
JUHE_BUSINESS_ID = 'yk'

# juhe 数据
# JUHE_APP_KEY = "2a2a0e7708b2a7079fdd340e70a8031f"
# JUHE_URL = "http://op.juhe.cn/ofpay/sinopec/ordersta?key={}&orderid={}"

# of
OF_URL = 'http://A1251451.api2.ofpay.com/api/query.do'
OF_USER_ID = 'A1251451'

# dhst
DHST_ACCOUNT = 'AdminKup'
# DHST_SIGN = '22a15a100c1329e089e3416899c921f5'
DHST_SIGN = 'd9f1264d9ddc6eb27268d2a49e971b52'
DHST_URL = 'http://if.dahanbank.cn/FCCheckOrderExistedServlet'

# tflow
TFLOW_URL = 'http://120.27.160.235:8083'
TFLOW_KEY = '5570a35a5f2948809ca1d8afd61f1aa1'
TFLOW_SECRET = '3EJNB6whSRVVd7BuFcTKmQxPkfL5wpl71TvshnUdgZQQiVzOeOlKiDHoFMRQ7lwd'

# sinopec
SINOPEC_URL = 'http://oil.19ego.cn/game/gameEsalesServlet.do'
SINOPEC_ID = 'OE20170414856325'
SINOPEC_KEY = 'UaWucEnyksHuQOKvjRyV2sVT1q0aKtCl'

# linqu
LQ_HOST = 'http://api.linjia.me:8080/api-server'
LQ_APP_KEY = '7C2D2FDD34017A01760C24AEBDD39AEB'
LQ_SOURCE = 'BOLUOME'

# cx580
CX_HOST = 'http://chaxun.cx580.com:9008/gateway.aspx'
CX_USER_ID = 'SHKP2017'
CX_USER_PWD = '65BFDE1E6D634A0DBAE4CB662CC5FAAC'

# yiguo
YG_URL = 'https://ygopen.yiguo.com/YGOpenAPI/values'  # https://ygopen.yiguo.com/YGOpenAPI/values
YG_CUSTOME_CODE = 'T-BLM'
YG_BIZ_SOURCE = '3941A7D740F6474B907BFBDC50B1E2CF'
YG_HEADERS = {'Content-Type': 'application/x-www-form-urlencoded'}

# quyiyuan
QYY_URL = 'https://open.quyiyuan.com:8443/v1.0'
QYY_FETCH_TOKEN_URI = '/access/token/get'
QYY_FETCH_URI = '/appointment/detail/get'
QYY_USERNAME = 'BoLuoMi310109'
QYY_PASSWORD = '21B5BA0F737EFAC3'

# shifendaojia
SFDJ_API_HOST = 'http://120.76.75.136:88/ha-thirdpart'
SFDJ_ACCESS_KEY = '0bc050540ae44d9a80ec389159b50af8'
SFDJ_ACCESS_KEY_SECRET = 'e9f345d7542749a4892e69e4f3d46eda'
SFDJ_VERSION = 'v1.0'
SFDJ_HEADERS = {'content-type': 'application/x-www-form-urlencoded'}
SFDJ_CODES = [20003, 20004, 20005, 20006, 20007]

# yongle
YONGLE_UNIONID = 62485393
YONGLE_URL = 'http://lm.228.cn/unionOrder'

# kaola
KAOLA_URL = 'http://thirdpart.kaola.com/api/'
KAOLA_CHANNEL_ID = '35195'
KAOLA_APP_KEY = '1912cc049d1f66b2daf49451dfb351b48cf7ba9d72bf591fc1f294c451c94450'
KAOLA_SECRET_KEY = '5295226c17645d477c5f19bebd947c9949eb9e8c37595abf6d1a6081b8a59d37'

# meituan
MEITUAN_URL = 'https://api-sqt.meituan.com'
MEITUAN_TOKEN = "KUPING-TK"
MEITUAN_SIGN = "4Zm8DApMlF4cXIxsjDzCpQ=="
MEITUAN_AES_KEY = "h1JdvF3UkZMtYyAVBa63wQ=="

# message
SUBMAIL_APPID_BLM = '10809'
SUBMAIL_APPID_ZHUANCHE = '10866'
SUBMAIL_APPID_JIUDIAN = '12029'
SUBMAIL_APPID_OTOSAAS = '12773'
SUBMAIL_APPID_MAIL = '11664'
SUBMAIL_APPID_VOICE = '20155'
SUBMAIL_APPKEY = {
    '10809': '2d6f317a9ee8d171cf9e385188798c18',
    '10866': '6ff684e3af6eb1ce7ea8c3e9c96b5f60',
    '12029': 'c49840b909bd29b7df7b48d942b7ad49',
    '12773': '1324fdded1ccce9f855300215985ab6c',
    '11664': '26a5a8c9fe31f28a60fa1f2558f9d8fd',
    '20155': '32968aca24b144386e918114e1f17586'
}
SUBMAIL_SMS_URL = 'https://api.submail.cn/message/xsend.json'
SUBMAIL_VOICE_URL = 'https://api.submail.cn/voice/verify.json'
SUBMAIL_MAIL_URL = 'https://api.submail.cn/mail/xsend'

SUBMAIL_PROJECT_REFUND_1 = 'GufTg2'
SUBMAIL_PROJECT_REFUND_2 = 'HQ8B21'
SUBMAIL_PROJECT_REFUND_3 = 'lLwjd'
SUBMAIL_LIULIANG_FAILED = 'uRRln3'
SUBMAIL_HUAFEI_FAILED = 'nmb7I'
SUBMAIL_ZHUANCHE_JIUWEI = 'FBYkH2'
SUBMAIL_DAIJIA_WEIJIEDAN = 'QkCBq'
SUBMAIL_DAIJIA_YIJIEDAN = 'B2iad3'
SUBMAIL_DAIJIA_JIUWEI = 'kj6O03'
SUBMAIL_PROJECT_HUOCHE = 'dNO4J3'
SUBMAIL_PROJECT_JIPIAO = 'VPEnD2'
SUBMAIL_PROJECT_DRIVER = 'KePGS1'
SUBMAIL_PROJECT_JHDP_JDQX = 'nKV7S2'
SUBMAIL_PROJECT_REPORT_MAIL = 'peKSO3'
SUBMAIL_PROJECT_CODE = 'zsgob3'

# jpush
JPUSH_KEY = 'e2a64d79e2a4167b2fcfbe35'
JPUSH_SECRET = 'dc6c935f8e1c9456567de55a'
JPUSH_APNS_PRODUCTION = True

# sina
SINA_SHORT_URL = 'https://api.weibo.com/2/short_url/shorten.json'
SINA_ACCESS_TOKEN = '2.00U594IGMNIfOE9ce281c586axetpD'

# order
ORDER_URL = 'https://boluome.otosaas.com/order'

REFUND_URL = 'http://refundapi.localdomain:21009/refund/save'

TASK_ARGS_SCHEMA = {
    'worker.cancel.cancel_fetch': {
        'type': 'array',
        'items': [
            {'type': 'string'},  # orderId
            {'type': 'string'},  # appCode
            {'type': 'string'},  # userId
            {'type': 'string'},  # couponId
            {'type': 'number'},  # couponPrice
            {'type': 'string'},  # activityId
            {'type': 'number'},  # activityPrice
            {'type': 'string'}  # completedAt
        ],
        'additionalItems': False,
        'minItems': 8
    },
    'worker.complete.complete_fetch': {
        'type': 'array',
        'items': [
            {'type': 'string'},  # appCode
            {'type': 'string'},  # orderId
            {'type': 'string'},  # userId
            {'type': 'string'},  # couponId
            {'type': 'string'},  # coupon
            {'type': 'string'},  # activityId
            {'type': 'string'},  # platformActivity
        ],
        'additionalItems': False,
        'minItems': 7
    },
    'worker.expire.expire_fetch': {
        'type': 'array',
        'items': [
            {'type': 'string'},  # orderType
            {'type': 'string'},  # orderId
            {'type': 'string'},  # appCode
            {'type': 'string'},  # userId
        ],
        'additionalItems': False,
        'minItems': 4
    },
    'worker.push.push_message_fetch': {
        'type': 'object',
        'properties': {
            'orderId': {'type': 'string'},
            'orderType': {'type': 'string'},
            'msgContent': {'type': 'string'},
            'contentType': {'type': 'string'},
            'title': {'type': 'string'},
            'extras': {'type': 'string'}},
        'additionalProperties': False,
        'required': ['orderId', 'orderType', 'msgContent', 'contentType', 'title', 'extras']
    },
    'worker.push.push_notification_fetch': {
        'type': 'object',
        'properties': {
            'orderId': {'type': 'string'},
            'orderType': {'type': 'string'},
            'userId': {'type': 'string'},
            'alert': {'type': 'string'}},
        'additionalProperties': False,
        'required': ['orderId', 'orderType', 'userId']
    },
    'worker.zzw.zzw_fetch': {
        'type': 'object'
    },
    'worker.kou.kou_fetch': {
        'type': 'object'
    },
    'worker.yidao.yidao_fetch_driver_info': {
        'type': 'object'
    },
    'worker.yidao.yidao_fetch_driver_location': {
        'type': 'object'
    },
    'worker.yidao.yidao_fetch_calculate': {
        'type': 'object'
    },
    'worker.yidao.yidao_fetch': {
        'type': 'object'
    },
    'worker.didi.didi_fetch': {
        'type': 'object'
    },
    'worker.ai.ai_fetch': {
        'type': 'object'
    },
    'worker.e.e_fetch': {
        'type': 'object'
    },
    'worker.ele.ele_fetch': {
        'type': 'object'
    },
    'worker.ele.ele_peisong_fetch': {
        'type': 'object'
    },
    'worker.linqu.linqu_fetch': {
        'type': 'object'
    },
    'worker.quyiyuan.quyiyuan_fetch': {
        'type': 'object'
    },
    'worker.refund.refund_fetch': {
        'type': 'object'
    },
    'worker.newer.newer_fetch': {
        'type': 'string'
    },
    'worker.newer.invite_newer_fetch': {
        'type': 'string'
    },
    'worker.sms.sms_short_url_fetch': {
        'type': 'object'
    },
    'worker.sms.sms_fetch': {
        'type': 'object'
    },
    'worker.sfdj.sfdj_fetch': {
        'type': 'object'
    }
}

# Order Status
#   | status | displayStatus | status | displayStatus |
#   | :----: | :-----------: | :----: | :-----------: |
#   | -1 | 已删除 | 13 | 退票中 |
#   | 0 | 异常   | 14 | 退票失败 |
#   | 1 | 已下单 | 15 | 已退票 |
#   | 2 | 待支付 | 16 | 等待部分退款 |
#   | 3 | 已支付 | 17 | 部分退款中 |
#   | 4 | 已完成 | 18 | 部分退款完成 |
#   | 5 | 取消中 | 19 | 改签审核中 |
#   | 6 | 退款中 | 20 | 改签审核失败 |
#   | 7 | 已退款 | 21 | 改签取消 |
#   | 8 | 已取消 | 22 | 改签中 |
#   | 9 | 处理中 | 23 | 改签成功 |
#   | 10 |订单失败 | 24 | 等待追加支付 |
#   | 11 | 等待退款 | 25 | 退款失败 |
#   | 12 | 支处理中 | 26 | 追加支付失败 |
ERR_STATUS_TRANSFER = [(11, 8), (6, 8), (7, 8), (7, 6), (7, 11), (6, 11), (8, 12), (4, 8), (4, 9), (3, 12),
                       (1, 1), (2, 2), (3, 3), (4, 4), (5, 5), (6, 6), (7, 7), (8, 8), (11, 11)]
YONGCHE_ERR_STATUS_TRANSFER = [(11, 8), (6, 8), (7, 8), (7, 6), (7, 11), (6, 11), (8, 12), (4, 8), (4, 9), (3, 12),
                               (1, 1), (2, 2), (3, 3), (4, 4), (5, 5), (6, 6), (7, 7), (8, 8), (11, 11), (8, 9)]
SENTRY_DNS = "http://6699950948a14bf49be9bd5e3f669d7e:207107ac001448d493a952f1799e3afc@sentry.boluome.com/33"

CTRIP_AID = {'oklife': {'Prepay': 698282, 'SelfPay': 698282}, 'other': {'Prepay': 328727, 'SelfPay': 263411}}
CTRIP_SID = {'oklife': {'Prepay': 1235859, 'SelfPay': 1235859}, 'other': {'Prepay': 810129, 'SelfPay': 712773}}
CTRIP_KEY = {
    'oklife': {'Prepay': '8EEA26EC-F03F-41B0-A0FB-F7B15E0E840D', 'SelfPay': '8EEA26EC-F03F-41B0-A0FB-F7B15E0E840D'},
    'other': {'Prepay': 'E0F33944-A048-45F7-AA91-A55196051B91', 'SelfPay': '1F100349-B1C2-4C92-B6CD-69BE97EAF7F8'}}
CTRIP_API_URL = 'openapi.ctrip.com'
CTRIP_ORDER_XML = ('<?xml version="1.0" encoding="utf-8"?>'
                   '<soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">'
                   '<soap:Body>'
                   '<Request xmlns="http://ctrip.com/">'
                   '<requestXML><![CDATA['
                   '<?xml version="1.0" encoding="utf-8"?>'
                   '<Request>'
                   '<Header AllianceID="{0}" SID="{1}" TimeStamp="{2}" RequestType=" D_HotelOrderMiniInfo" Signature="{3}" />'
                   '<HotelOrderMiniInfoRequest>'
                   '<AllianceId>{0}</AllianceId>'
                   '<Sid>{1}</Sid>'
                   '<OrderId>{4}</OrderId>'
                   '</HotelOrderMiniInfoRequest>'
                   '</Request>]]>'
                   '</requestXML>'
                   '</Request>'
                   '</soap:Body>'
                   '</soap:Envelope>')

PURCHASE_QUOTA_CUSTOMERS = {'mybosc': (0, 500, 0)}

# 订单中心API
SAASAPI_ORDER_CENTER = 'http://orderapi.localdomain:21003'

SAASAPI_YONGLE = 'http://piaowuapi.localdomain:31011'

# session API
SESSIONAPI = 'http://sessionapi.localdomain:8010'

# rabbitmq API
RABBITMQAPI = 'http://rmqrestapi.localdomain:8672'

# oto_saas_coupon
SAASAPI_COUPON = "http://couponapi.localdomain:38803"

# 核销通知
notice_url_general = 'http://lb30.localdomain:32037/{}/v1/coupon/status'  # 核销通知通用接口
zjrcu_cancel_notice_url = 'http://lb30.localdomain:32035/zjrcu/coupon/cancel/v1'
jifenquan_notice_url = 'http://lb30.localdomain:31073/v1/voucher/status'  # 积分券和消状态通知


MQ_ELK_REQUEST_STATUS = 'yunwei_elk_request_status_tasks'
